package com.blockchain.console.servlets.financial.bzc;

import javax.servlet.http.HttpServletRequest;
import javax.servlet.http.HttpServletResponse;

import com.blockchain.common.enums.XlbZcStatus;
import com.blockchain.console.service.financial.BManage;
import com.blockchain.console.servlets.financial.AbstractFinancialServlet;
import com.blockchain.framework.http.servlet.annotation.Right;
import com.blockchain.framework.service.ServiceSession;
import com.blockchain.util.parser.IntegerParser;

@Right(id = "C_FINANCIAL_XLBYC", name = "虚拟币转出-审核通过-异常")
public class XlbYc extends AbstractFinancialServlet {
	private static final long serialVersionUID = 1L;

	@Override
	protected void processGet(HttpServletRequest request, HttpServletResponse response, ServiceSession serviceSession)
			throws Throwable {
		processPost(request, response, serviceSession);
	}

	@Override
	protected void processPost(final HttpServletRequest request, final HttpServletResponse response,
			final ServiceSession serviceSession) throws Throwable {
		BManage manage = serviceSession.getService(BManage.class);
		int  id =IntegerParser.parse(request.getParameter("id")); 
		String hax=request.getParameter("bz");
		manage.xlbYccl(id, hax);
		sendRedirect(request, response, getController().getURI(request, BzcList.class) + "?zczt=" + XlbZcStatus.ZCCG.name());
	}
}
